Within computer operations, and particularly in the development of software for use with personal computers (PCs), it is desirable to provide standards to facilitate portability of the software from one computer system to another. The promotion of standards also encourages the development of high quality numerical software. This is particularly important in the microprocessor and small machine environment, such as the PC environment, where individual manufacturers are not likely to develop extensive, generally usable numerical routines.
One standard format particularly used for storing floating point numbers is that developed by the Computer Society of the Institute of Electrical and Electronics Engineers (IEEE) for storing 64-bit floating point numbers. In accordance with the IEEE standard, a first bit is provided to represent the sign bit, the next 11 bits are provided to represent the exponent of the floating point number, and the remaining 52 bits are provided to represent the mantissa (FIG. 1). As is known in the art, the IEEE standard is ideal for representing floating point numbers for use in basic arithmetic operations as well as in scientific arithmetic operations. The IEEE standard has been widely adopted by software developers and manufacturers, particularly those developers and manufacturers of software for the personal computing environment.
However, many users of such software, and several applications in which the standard is employed, do not require the full capability provided by the IEEE standard. As an example, many users of spreadsheets that typically employ the IEEE standard desire to express numbers in terms of simply a dollar amount or a percentage. For these users, storing of a number having an eleven digit exponent is unnecessary. Many other users of software that employ the IEEE standard only have a need for storing small numbers, such as three- or four-digit numbers, that can be stored without using the full 52-bit mantissa provided by the standard. For each of these users, and many others, the IEEE standard represents a tremendous storage overhead, depriving them of memory space that could be used for other operations.
Accordingly, it is desirable to provide a method for storing floating point numbers, which method minimizes the amount of memory needed for storage of the number. Further, it is desirable to provide a method for storing numbers presented in the standard IEEE format wherein the numbers can be readily returned to the IEEE format for later use.